Upd grammar, better help loading
authorJeroen van der Heijden <jeroen@transceptor.technology>
Fri, 29 Jun 2018 20:51:53 +0000 (22:51 +0200)
committerJeroen van der Heijden <jeroen@transceptor.technology>
Fri, 29 Jun 2018 20:51:53 +0000 (22:51 +0200)
grammar/gogrammar/grammar.go
include/siri/grammar/grammar.h
src/siri/grammar/grammar.c
src/siri/parser/listener.c

index b61dd6fcc745f7a149549ebb14394d3b3d9dc1ad..e737c79bf4b24a3602d3d9a9b445bf3f96c4aa69 100644 (file)
@@ -4,7 +4,7 @@ package grammar
 // should be used with the goleri module.
 //
 // Source class: SiriGrammar
-// Created at: 2018-06-29 17:12:20
+// Created at: 2018-06-29 22:48:05
 
 import (
        "regexp"
index 44568b647b167a55a442fce2d3c8625793ac0ee8..1e51a7c6320d8ead170ce4331809e42c0b8eec2e 100644 (file)
@@ -5,7 +5,7 @@
  * should be used with the libcleri module.
  *
  * Source class: SiriGrammar
- * Created at: 2018-06-29 17:09:17
+ * Created at: 2018-06-29 22:48:05
  */
 #ifndef CLERI_EXPORT_SIRI_GRAMMAR_GRAMMAR_H_
 #define CLERI_EXPORT_SIRI_GRAMMAR_GRAMMAR_H_
index dad86d35f61f5db245cebf184f37337cd1586d4b..467913e087c1dc3e9c6d67415c061f6be926cf70 100644 (file)
@@ -5,7 +5,7 @@
  * should be used with the libcleri module.
  *
  * Source class: SiriGrammar
- * Created at: 2018-06-29 17:09:17
+ * Created at: 2018-06-29 22:48:05
  */
 
 #include "siri/grammar/grammar.h"
@@ -1653,7 +1653,7 @@ cleri_grammar_t * compile_grammar(void)
     cleri_t * help_timeit = cleri_keyword(CLERI_GID_HELP_TIMEIT, "timeit", CLERI_CASE_SENSITIVE);
     cleri_t * help_timezones = cleri_keyword(CLERI_GID_HELP_TIMEZONES, "timezones", CLERI_CASE_SENSITIVE);
     cleri_ref_set(help_stmt, cleri_sequence(
-        CLERI_NONE,
+        CLERI_GID_HELP_STMT,
         2,
         k_help,
         cleri_optional(CLERI_NONE, cleri_choice(
index bdce95396f9a0bb5a8a2ddc49509d634a21282bc..f771f3f0c47dc0df8d4a790ba70efc39cb6690b0 100644 (file)
@@ -846,7 +846,6 @@ static void enter_group_match(uv_async_t * handle)
 
 static void enter_help(uv_async_t * handle)
 {
-    LOGC("Enter!!");
     siridb_query_t * query = (siridb_query_t *) handle->data;
 
     cleri_node_t * node = query->nodes->node;
@@ -2726,14 +2725,11 @@ static void exit_help_xxx(uv_async_t * handle)
 {
     siridb_query_t * query = (siridb_query_t *) handle->data;
 
-    LOGC("HERE....");
-
     if (query->data != NULL)
     {
 #if DEBUG
         assert (query->packer == NULL);
 #endif
-        LOGC("HERE1....%u", query->nodes->node->cl_obj->gid);
         const char * help = siri_help_get(
                 query->nodes->node->cl_obj->gid,
                 (const char *) query->data,
@@ -2741,7 +2737,6 @@ static void exit_help_xxx(uv_async_t * handle)
 
         if (help == NULL)
         {
-            LOGC("HERE2....");
             siridb_query_send_error(handle, CPROTO_ERR_QUERY);
             return;
         }